﻿<Window x:Class="MCServerHelper.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:this="clr-namespace:MCServerHelper"
        Title="MC Server Helper" Height="548" Width="591"
        FocusManager.FocusedElement="{Binding ElementName=inputBox}">
    <Window.CommandBindings>
        <CommandBinding Command="{x:Static this:MainWindow.SendInput}" CanExecute="CommandBinding_CanExecute" Executed="CommandBinding_Executed"/>
    </Window.CommandBindings>
    <Window.InputBindings>
        <KeyBinding Key="Enter" Command="{x:Static this:MainWindow.SendInput}"/>
    </Window.InputBindings>
    <Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
        <Grid.RowDefinitions>
            <RowDefinition/>
            <RowDefinition Height="Auto"/>
        </Grid.RowDefinitions>
        <ScrollViewer x:Name="outputScroll" Grid.Row="0" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="10,10,10,0">
            <TextBlock  x:Name="outputBox" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"/>
            </ScrollViewer>
        <Grid Grid.Row="1">
        	<Grid.ColumnDefinitions>
        		<ColumnDefinition/>
        		<ColumnDefinition Width="Auto"/>
        	</Grid.ColumnDefinitions>
        	<TextBox  x:Name="inputBox" HorizontalAlignment="Stretch" Margin="10" VerticalAlignment="Top"/>
            <Button Content="Send" HorizontalAlignment="Left" VerticalAlignment="Top" Grid.Column="1" Width="100" Height="25" Margin="10"
                    Command="{x:Static this:MainWindow.SendInput}">
               
            </Button>
        </Grid>
    </Grid>
</Window>
